package com.lcb.storage.service;

import com.lcb.common.utils.BaseResponse;
import com.lcb.storage.entity.TStorage;
import org.springframework.web.bind.annotation.*;

/****
 * @Author:lcb
 * @Description:TStorage业务层接口
 * @Date: 2021-01-28 11:29:40
 *****/
public interface TStorageService {

    @PostMapping("/stroage/decrease")
    BaseResponse decrease(@RequestBody TStorage storage);

    /***
     * TStorage多条件分页查询
     * @param tStorage
     * @param page
     * @param size
     * @return
     */
    @GetMapping("/findTStorageList/{page}/{size}")
    BaseResponse findTStorageList(@RequestBody TStorage tStorage, @PathVariable(value = "page") int page, @PathVariable(value = "size") int size);

    /***
     * 删除TStorage
     * @param ids
     */
    @DeleteMapping("/deleteTStorageById/{ids}")
    BaseResponse deleteTStorageById(@PathVariable(value = "ids") String ids);

    /***
     * 修改TStorage数据
     * @param tStorage
     */
    @PutMapping("/updateTStorage")
    BaseResponse updateTStorage(@RequestBody TStorage tStorage);

    /***
     * 新增TStorage
     * @param tStorage
     */
    @PostMapping("/addTStorage")
    BaseResponse addTStorage(@RequestBody TStorage tStorage);

    /**
     * 根据ID查询TStorage
     * @param id
     * @return
     */
    @GetMapping("/findTStorageById/{id}")
    BaseResponse findTStorageById(@PathVariable("id") Long id);

    /***
     * 查询所有TStorage
     * @return
     */
    @GetMapping("/findTStorageAll")
    BaseResponse findTStorageAll();
}
